<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<jsp:include page="../links.jsp"></jsp:include>
<script type="text/javascript">
	$(function() { 
		var businessUpdate_form;
		businessUpdate_form = $('#businessUpdate_form').form({
			url : getRootPath() + '/businessAction/b_update.do',
			success : function(r) {
				r = $.parseJSON(r);//将标准json转成obj
				if (r && r.success) {
					$.messager.show({
						title : '提示',
						msg : '修改成功',
						showType : 'show'
					});
				} else {
					$.messager.alert('提示', '更新失败');
				}
			}
		});
		business_update_fun = function() {
			if ($('#b_id1').val() == null || $('#b_id1').val() == "") {
				$.messager.alert('提示', '请输入业务编号');
				return false;
			}
			if ($('#uid1').val() == null || $('#uid1').val() == "") {
				$.messager.alert('提示', '请输入用户编号');
				return false;
			}
			if ($('#cid1').val() == null || $('#cid1').val() == "") {
				$.messager.alert('提示', '请输入客户编号');
				return false;
			}
			if ($('#b_business1').val() == null || $('#b_business1').val() == "") {
				$.messager.alert('提示', '请输入合作业务');
				return false;
			}
			if ($('#b_evaluate1').val() == null || $('#b_evaluate1').val() == "") {
				$.messager.alert('提示', '请输入业务评价');
				return false;
			} else {
				$('#businessUpdate_form').submit();
			}
			return true;
		}
	})
</script>
<div id="businessUpdate" style="position: absolute; left: 32%; top: 10%;">
	<form id="businessUpdate_form" method="post">
		<table cellpadding="5">
			<tr>
				<th>业务标号</th>
				<td><input id="b_id1" class="easyui-validatebox" type="text" name="b_id" data-options="novalidate:true "></input></td>
			</tr>
			<tr>
				<th>用户编号</th>
				<td><input id="uid1" class="easyui-validatebox" type="text" name="uid" data-options="novalidate:true "></input></td>
			</tr>
			<tr>
				<th>客户编号</th>
				<td><input id="cid1" class="easyui-validatebox" type="text" name="cid" data-options="novalidate:true "></input></td>
			</tr>
			<tr>
				<th>合作业务</th>
				<td><input id="b_business1" class="easyui-validatebox" type="text" name="b_business"
					data-options="novalidate:true "></input></td>
			</tr>
			<tr>
				<th>业务评价</th>
				<td><textarea id="b_evaluate1" class="easyui-validatebox" type="text" name="b_evaluate"
						data-options="novalidate:true " style="height: 70px; width: 155px;"></textarea></td>
			</tr>
			<tr>
				<td colspan="2"><span><a href="javascript:;" class="easyui-linkbutton" style="width: 288px;"
						onclick="business_update_fun()"><font color="red">修改业务信息</font></a></span></td>
			</tr>
		</table>
	</form>
</div>